local skel = fk.CreateSkill {
  name = "efengqi__juxiang",
  tags = {Skill.Compulsory},
}

Fk:loadTranslationTable{
  ["efengqi__juxiang"] = "巨象",
  [":efengqi__juxiang"] = "锁定技，【南蛮入侵】和火【杀】对你无效，其他角色使用的上述牌结算后，你获得之。",

  ["$efengqi__juxiang1"] = "大王，看我的。",
  ["$efengqi__juxiang2"] = "大象很厉害吧！",
}

skel:addEffect(fk.PreCardEffect, {
  audio_index = 1,
  anim_type = "defensive",
  can_trigger = function(self, event, target, player, data)
    return player:hasSkill(skel.name) and data.to == player
    and (data.card.name == "savage_assault" or data.card.name == "fire__slash")
  end,
  on_use = function (self, event, target, player, data)
    data.nullified = true
  end,
})

skel:addEffect(fk.CardUseFinished, {
  audio_index = 2,
  anim_type = "drawcard",
  can_trigger = function(self, event, target, player, data)
    return target ~= player and player:hasSkill(skel.name) and player.room:getCardArea(data.card) == Card.Processing and
      (data.card.name == "savage_assault" or data.card.name == "fire__slash")
  end,
  on_use = function(self, event, target, player, data)
    player.room:obtainCard(player, data.card, true, fk.ReasonJustMove, player, skel.name)
  end,
})

return skel
